import httpInstance from "@/utils/http"

// 获取轮播数据
export function getBannerAPI (params = {}) {
    //  默认 1  商品 2
    const { distributionSite = '1' } = params
    return httpInstance({
        url: '/home/banner',
        params: {
            distributionSite
        }
    })
}

// 获取新鲜好物数据
export function getNewAPI () {
    return httpInstance({
        url: '/home/new'
    })
}

// 获取热门品牌数据
export const getHotAPI = () => {
    return httpInstance.get('/home/hot', {})
}

// 获取所有商品数据
export function getGoodsAPI () {
    return httpInstance.get('/home/goods')
}